<template>
  <view class="guess-wrap">
    <view class="caption">
      <image src="../../../static/images/bubble.png" />
      <text style="padding: 0 10px" class="text">猜你喜欢</text>
      <image src="../../../static/images/bubble.png" />
    </view>
    <view class="guess">
      <navigator
        class="navigator"
        v-for="item in guessObj"
        :key="item.id"
        :url="`/pages/goods/goods?id=${item.id}`"
      >
        <image class="image" mode="aspectFill" :src="item.picture"></image>
        <view class="name">{{ item.name }}</view>
        <view class="price">
          <text class="small">¥</text>
          {{ item.price }}
          <text class="small">.00</text>
        </view>
      </navigator>
    </view>
    <!-- 没有更多数据了 -->
    <view class="loading" v-if="false">正在加载...</view>
  </view>
</template>

<script setup>

  const props =defineProps({
    guessObj:{
      type:Array,
      default:()=>[]
    }
  })
</script>


<style lang="scss" scoped>
.caption{
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px 0;
  image{
    width: 8px;
    height: 8px;
  }
}
.guess{
  padding:0 40rpx;
  display: flex;
  width: 670rpx;
  flex-wrap: wrap;
  justify-content: space-between;
  navigator{
    margin-top: 50rpx;
    width: 320rpx;
    height: 480rpx;
    image{
      width: 100%;
      height: 80%;
    }
  }
}
</style>
